#pragma once
#include "pch.h"
#include "Common.h"
#include <QObject>
#include <QThread>
#include <QMetatype>
#include <liblas/liblas.hpp>

namespace AutomatedSurfaceReconstruction
{
	class CPointCloud :public QObject
	{
		Q_OBJECT
	public:
		explicit CPointCloud(QObject* vPparent = nullptr);

	signals:
		void FinishLoadPointCloud(std::string vFileName, PCLPointSetType::Ptr vOriginPointCloud, CGALPointSetType vSimpfiedPointCloud, CGALPointSetType vDXFPointCloud);
		void FinishLoadAllPointCloud();

	public slots:
		void onActionLoadPointCloud(std::vector<std::string> vFilePathSet, std::unordered_map<std::string, PCLPointSetType::Ptr> vioFilePath2PointCloud);

	private:
		std::string __getOnlyFileName(const std::string& vFileName, const std::string& vFileSuffix, const std::unordered_map<std::string, PCLPointSetType::Ptr>& vFilePath2PointCloud);
		std::string __getSuffix(const std::string& vFilePath);
	};
}